<template>
  <div>
    <el-table
      :data="cardList.filter(data => !search || data.name.toLowerCase().includes(search.toLowerCase()))"
      style="width: 100%">

      <el-table-column
        label="Id"
        prop="id">
      </el-table-column>

      <el-table-column
        label="姓名"
        prop="name">
      </el-table-column>

      <el-table-column
        label="手机号"
        prop="mobile">
      </el-table-column>


      <el-table-column
        label="公司"
        prop="company">
      </el-table-column>

      <!--      <el-table-column-->
      <!--        label="职位"-->
      <!--        prop="position">-->
      <!--      </el-table-column>-->

      <!--      <el-table-column-->
      <!--        label="出生日期"-->
      <!--        prop="birthday">-->
      <!--      </el-table-column>-->


      <el-table-column
        align="right">
        <template slot="header" slot-scope="scope">
          <el-input
            v-model="search"
            size="mini"
            placeholder="输入关键字搜索"/>
        </template>
        <template slot-scope="scope">
          <el-button
            size="mini"
            @click="handleLook( scope.row)">查看</el-button>
          <el-button
            size="mini"
            type="danger"
            @click="handleLike(scope.row)">喜欢</el-button>
        </template>
      </el-table-column>
    </el-table>
  </div>
</template>

<script>
export default {
  name: "CardLike"
}
</script>

<style scoped>

</style>
